package com.lesserpand.springcloudalibabaconsumer.security.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author bailuo
 * @version 2.0
 * @Description TODO
 * @Date Created in 2018/12/11 14:40
 */
@RestController
@RequestMapping("/consumer-test")
public class SecurityOauthController {

    private static final Logger LOGGER = LoggerFactory.getLogger(SecurityOauthController.class);


    /**
     * 授权码模式，获取code
     * @param clientId
     * @param redirectUri
     * @return
     */
    @GetMapping("/authorize")
    public String authorize(String clientId, String redirectUri) {
        String code = "clientId";
        LOGGER.info(code);
        return code;
    }

}
